angular.module('meMoreRuleServices', [])

  .factory('MoreRule', function ($resource, $rootScope, ENV, Storage) {

    //设置访问接口路径
    var APIUrl = ENV.api;

    //访问获取用户信息的接口
    var pointIntroResource = $resource(APIUrl + "meMore/getPointIntro.do");

    var pointRuleJson;

    return {

      //获取规则信息
      getPointIntro : function () {
        pointIntroResource.save(
          {},
          function (data) {
            pointRuleJson = data;
            $rootScope.$broadcast('Me.getPointIntro');
          }
        );
      },

      getPointIntroJson : function(){
        return pointRuleJson;
      }
    }

  });
